﻿/************************************************************************

 This file is part of EscapeFromPrisonPlanet.

 EscapeFromPrisonPlanet is free software: you can redistribute it and/or modify
 it under the terms of the GNU General Public License as published by
 the Free Software Foundation, either version 3 of the License, or
 (at your option) any later version.

 EscapeFromPrisonPlanet is distributed in the hope that it will be useful,
 but WITHOUT ANY WARRANTY; without even the implied warranty of
 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 GNU General Public License for more details.

 You should have received a copy of the GNU General Public License
 along with Foobar.  If not, see <http://www.gnu.org/licenses/>.

************************************************************************/

// All code (c)2012 Scott Bevin. all rights reserved

using Microsoft.Xna.Framework.Content;
using Microsoft.Xna.Framework.Graphics;

namespace LudumDare25Project
{
    internal class GameScreen
    {
        public bool KillScreen = false;
        public bool Fullscreen = false;

        public bool TopMostScreen { get { return GameScreenManager.GameScreens[GameScreenManager.GameScreens.Count - 1] == this; } }

        protected GameMain Game = null;
        protected ContentManager ContentManager = null;
        protected GameScreenManager GameScreenManager = null;

        public GameScreen(bool fullscreen)
        {
            this.Fullscreen = fullscreen;
        }

        public void Setup(GameScreenManager gsm, GameMain game)
        {
            Game = game;
            GameScreenManager = gsm;
            ContentManager = new ContentManager(game.Services);
            ContentManager.RootDirectory = "Content";
        }

        virtual public void OnAdded()
        {
        }

        virtual public void Update(float dt, InputManager input)
        {
        }

        virtual public void Render(float dt, GraphicsDevice gd, SpriteBatch sprites)
        {
        }

        virtual public void OnRemoved()
        {
        }
    }
}